package homework25;

public class Car {
    String brand;
    double price;

    // 空参构造器
    public Car() {
        System.out.println("调用Car的空参构造器");
    }

    // 全参构造器
    public Car(String brand, double price) {
        this.brand = brand;
        this.price = price;
        System.out.println("调用Car的全参构造器：" + brand + "，价格：" + price);
    }
}
